<?php 
/**
 * Customize the flash message
 *
 * PHP versions 4 and 5
 *
 * TutoriumBase (http://tutoriumbase.my-reality.de)
 * Copyright 2012, Miguel Gonzalez (http://my-reality.de)
 *
 *
 * @copyright     Copyright 2012, Miguel Gonzalez (http://my-reality.de)
 * @link          http://tutoriumbase.my-reality.de TutoriumBase
 * @since         TutoriumBase v 0.1
 */


// Detect the color of the button
$color = 'button_yellow';

if ($class == 'success')
{
    $color = 'button_green';
} else if ($class == 'fail')
{
    $color = 'button_red';
} 

?>

<div id="flashMessage"<?php echo isset($class) ? 'class="' . $class . ' ' . $color . '"' :  'class="' . $color . '"'; ?>>
    <div class="left">
        <div id="flash_image" <?php echo 'class="' . $class . '"'?>></div>
    </div>
    <div class="right">
        <?php echo isset($message) ? $message :  NULL; ?>
    </div>
</div> 